import request from '@/utils/request'
export function fetchList(data) {
  return request({
    url: '/v1/advertise/list',
    method: 'post',
    data: data
  })
}
export function updateStatus(data) {
  return request({
    url: '/v1/advertise/updateStatus',
    method: 'post',
    data: data
  })
}
export function deleteHomeAdvertise(id) {
  return request({
    url: `/v1/advertise/delete/${id}`,
    method: 'post'
  })
}

export function batchDeleteHomeAdvertise(ids) {
  return request({
    url: `/v1/advertise/delete/batch`,
    method: 'post',
    data: ids
  })
}
export function createHomeAdvertise(data) {
  return request({
    url: '/v1/advertise/add',
    method: 'post',
    data: data
  })
}
export function getHomeAdvertise(id) {
  return request({
    url: `/v1/advertise/selectOne/${id}`,
    method: 'get'
  })
}

export function updateHomeAdvertise(data) {
  return request({
    url: '/v1/advertise/update',
    method: 'post',
    data: data
  })
}
